<?php

namespace app\common\traits;

use app\common\service\AreaService;
use function app;

/**
 * 定位
 * Trait LocationTrait
 * @package app\common\traits
 */
trait AreaTrait
{

    private function getProvinceCityByPhone($phone): array
    {
        return $this->getAreaService()->getProvinceCityByPhone($phone);
    }

    private function getAreaService(): AreaService
    {
        return app(AreaService::class);
    }
}